import { http } from '@/utils/request'

const userRouteURL = '/api/user'


export function apiLogin(data) {
  return http.post(userRouteURL+'/adminLogin', data)
}

export function apiLogout() {
  return http.delete(userRouteURL)
}

export function apiFindUsers(params) {
  const { page, pageSize, no, email } = params
  return http.post(userRouteURL+`/list?page=${page}&&pageSize=${pageSize}`,{no,email})
}

export function apiChangeInfo(data) {
  return http.put(userRouteURL+`/changeInfo`,data)
}

export function apiResetPassword(data) {
  return http.put(userRouteURL+`/resetPassword`,data)
}
